#pragma once

#include <fmt/core.h>
#include <fmt/color.h>

#ifdef DEBUG
#define LOG_E(...)                                                                                               \
    do                                                                                                           \
    {                                                                                                            \
        fmt::print(fg(fmt::color::crimson) | fmt::emphasis::bold, "ERROR:[{} line : {}]  ", __FILE__, __LINE__); \
        fmt::print(fg(fmt::color::crimson) | fmt::emphasis::bold, __VA_ARGS__);                                  \
        fmt::print("\n");                                                                                        \
    } while (0);

#define LOG_I(...)                                                                      \
    do                                                                                  \
    {                                                                                   \
        fmt::print(fg(fmt::color::green), "INFOR:[{} line : {}] ", __FILE__, __LINE__); \
        fmt::print(fg(fmt::color::green), __VA_ARGS__);                                 \
        fmt::print("\n");                                                               \
    } while (0);
#else
#define LOG_E(...)
#define LOG_I(...)
#endif
